package com.jhgsys.internal.accident.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.jhgsys.internal.accident.entity.AccidentReportReason;
import lombok.Data;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * @author MrBird
 */
@Data
public class AccidentReportTree implements Serializable {

    private static final long serialVersionUID = 7681873362531265829L;

    private String id;
    private String parentId;
    private String name;
    private String value;
    private boolean hasParent = false;
    private boolean hasChild = false;

    private String reportId;
    private String tenantId;
    private String tenantName;
    private String accidentNo;
    private String accidentTitle;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date accidentDate;

    private String accidentAreaId;
    private String accidentAreaName;
    private String accidentType;
    private String accidentLevel;

    private String leaderUserId;
    private String leaderUserName;
    private String leaderUserNo;
    private String leaderRealName;
    private String leaderDeptId;
    private String leaderDeptName;

    private String status;
    private String surveyStatus;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date surveyDeadline;
    private String surveyDeptId;
    private String surveyDeptName;
    private String surveyUserId;
    private String surveyRealName;
    private String surveyRemark;

    private String createdBy;
    private String deletedFlg;

    private List<AccidentReportReason> children = new ArrayList<>();

}